//
//  imageCollectionViewCell.m
//  FCTools
//
//  Created by WJC on 2018/10/29.
//  Copyright © 2018 wjc. All rights reserved.
//

#import "imageCollectionViewCell.h"
#import "WJCDefine.h"
//#import "SVProgressHUD.h"
//#import "MJExtension.h"
#import "Masonry.h"
@implementation imageCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame{
    self=[super initWithFrame:frame];
    if (self) {
            //        self.backgroundColor=[UIColor whiteColor];
        _imageView=[UIImageView new];
        [self addSubview:_imageView];
        _imageView.frame=CGRectMake(0, 0, frame.size.width, frame.size.height-15);
        
        self.titleName=[UILabel new];
        WJCWeakSelf
        self.titleName.font=font13;
        self.titleName.frame=CGRectMake(0, frame.size.height-15, frame.size.width, 15);
        self.titleName.textAlignment=NSTextAlignmentCenter;
        [self addSubview:self.titleName];
        [self.titleName mas_makeConstraints:^(MASConstraintMaker *make) {
            make.left.and.right.mas_equalTo(0);
            make.height.mas_greaterThanOrEqualTo(15);
            make.bottom.mas_equalTo(0);
            
        }];
        [_imageView mas_makeConstraints:^(MASConstraintMaker *make) {
            
            make.top.and.left.and.right.mas_equalTo(0);
            make.bottom.equalTo(weakSelf.titleName.mas_top);
        }];
    }
    return self;
}
@end
